<form class="form-horizontal" role="form" name="logFrom" novalitedate>
  <div class="form-ctrl md-whiteframe-z1">
    <div class="form-search" style="height:220px;" ng-class="{true: 'shou'}[shoumun==0]" ng-switch on="querterCondition">
      <div>
      <label style="">查询条件</label>
        <md-select ng-model="querterCondition" >
        <md-option ng-value="querter.querterCode"  ng-repeat="querter in querters">{{querter.querterName}}</md-option>
        </md-select>
      </div>

        <div  ng-switch-when='04'>
         <md-input-container flex >
           <input  name="roleCode" ng-model='role.roleCode'></input>
        </md-input-container>
      </div>

       <div  ng-switch-when='01'>
         <md-input-container flex >
           <input  name="roleName" ng-model='role.roleName'></input>
        </md-input-container>
      </div>

   <!--    <div ng-switch-when='03'>
        <label>上级角色</label>
        <md-select  ng-model="role.parentName" >
            <md-option ng-value="role.roleName"  ng-repeat="role in roles">{{role.roleName}}</md-option>
        </md-select>
      </div>   -->

      <div  ng-switch-when='02'>
        <md-input-container flex>
        <label >创建时间</label>
        <input   type="date"  required  name="startTime" ng-model="role.creTime"  time-date='date'>
        <div ng-messages="logFrom.startTime.$error">
          <div ng-message="date">请正确输入时间</div>
          <div ng-message="required">必填</div>
          <div ng-message="too-great">时间必须小于当前时间</div>
        </div>
      </md-input-container>
      </div>
    </div>
    <!-- 查询按钮 -->
      <i class="glyphicon glyphicon-chevron-up shrinkage" ng-click="shoumun=0"></i>
       <md-button ng-click="queryAllChannel()" ng-click="shoumun==1?shoumun=0:shoumun=1" class="md-fab md-primary md-hue-1" ng-disabled ='stForm.$invalid' aria-label="Profile">
                <i class="glyphicon glyphicon-arrow-down" style="margin-top:28px;" ng-show="shoumun==0"></i>
                <i class="glyphicon glyphicon-search" ng-show="shoumun==1"></i>
        </md-button>
  </div>
</form>
     <div class="menus">
      <md-button class="md-raised" ng-click="roleAdd($event)">添加角色</md-button>
      <md-button class="md-raised" ng-disabled="!(data.roleIds.length === 1)"  ng-click="roleUpdate($event)" >修改角色</md-button>
      <md-button class="md-raised" ng-disabled="!(data.roleIds.length >0)" ng-click="showConfirm()" >删除角色</md-button>
      </br>
    </div>

   <div class="table-detail">
      <div class="t_r">
        <table class="table table-bordered">
          <thead>
             <tr>
               <th></th>
               <th>角色编号</th>
               <th>角色名称</th>
              <!--  <th>上级角色</th> -->
               <th>创建时间</th>
               <th>角色说明</th>
            </tr>
          </thead>
         <tbody>
           <tr ng-repeat="role in items">
             <td style="text-align: center;">
               <md-checkbox  aria-label="Checkbox1"  ng-model='index' ng-click="check(role)" style="margin: 0px"></md-   checkbox>
             </td>
             <td><span>{{role.roleCode}}</span></td>
             <td><span >{{role.roleName}}</span></td>
<!--              <td><span>{{role.parentName}}</span></td> -->
             <td><span >{{role.creTime}}</span></td>
             <td><span >{{role.roleDetail}}</span></td>
           </tr>
      </tbody>
        </table>
       </div>
    </div>






